package com.day0009;
//矩形
public class Rectangle extends Shape {

    public Rectangle(int chang, int kuan) {
        super(chang, kuan);
    }

    @Override
    public double perimeter() {
        return (getChang()+getKuan())*2;
    }

    @Override
    public double area() {
        return getChang()*getKuan();
    }
}
